Skip to content

[UR][L0][L0v2] Refactor reference counting in UR L0 and L0v2 #19057

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Jul 2, 2025

Conversation

martygrant
Copy link
Contributor

@martygrant martygrant commented Jun 18, 2025

For #18644

Most UR adapters had their own reference counting of some sort. This adds a new RefCount class and refactors adapter code so all adapters can share the same code for reference counting. This PR handles L0/L0V2 and I will open more PRs for each adapter in turn.

@martygrant martygrant force-pushed the refCountRefactorL0 branch from 8e897f6 to d5ce48c Compare June 20, 2025 14:16
@martygrant martygrant marked this pull request as ready for review June 23, 2025 09:02
@martygrant martygrant requested review from a team as code owners June 23, 2025 09:02
@martygrant martygrant force-pushed the refCountRefactorL0 branch 2 times, most recently from 08d30d0 to 080a36d Compare June 25, 2025 11:51
@martygrant martygrant force-pushed the refCountRefactorL0 branch from 080a36d to 331bfb1 Compare June 25, 2025 14:19
@martygrant martygrant force-pushed the refCountRefactorL0 branch from 331bfb1 to 658e368 Compare June 25, 2025 14:29
@martygrant martygrant force-pushed the refCountRefactorL0 branch from 658e368 to 6b2c4bb Compare June 25, 2025 14:45
martygrant added a commit to martygrant/llvm that referenced this pull request Jun 27, 2025
@martygrant martygrant force-pushed the refCountRefactorL0 branch from 44b4c09 to 17bb480 Compare July 2, 2025 08:37
@martygrant martygrant force-pushed the refCountRefactorL0 branch from 17bb480 to ebcbfa0 Compare July 2, 2025 08:45
martygrant added a commit to martygrant/llvm that referenced this pull request Jul 2, 2025
…to inherit common reference counting functionality. Update L0 and L0V2 to use this.
…to any relevant handles that need ref counting.
…espace. Add a constructor for the class with a default value and remove use of reset() inside the Adapter constructor, using the RefCount constructor to set default value instead.
…nd decrementAndTest -> release, and remove decrement as it doesn't get used.
@martygrant
Copy link
Contributor Author

Failing e2e_test_requirements/no_sycl_hpp_in_e2e_tests.cpp test is being fixed with #19260

@martygrant martygrant merged commit e98d8a0 into intel:sycl Jul 2, 2025
32 of 33 checks passed
martygrant added a commit to martygrant/llvm that referenced this pull request Jul 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants